QuickTime 4 API Documentation

3D Graphics Programming with QuickDraw 3D 1.5.4

Previous | QD3D Book | Overview | Chapter Contents | Next |

Spot Lights

A spot light is a light source that emits a circular cone of light in a specific direction from a specific location. Figure 11 shows the geometry of a spot light. Every spot light has a hot angle and an outer angle that together define the shape of the cone of light and the amount of attenuation, if any, that occurs from the center of the cone to the outer edge of the cone.

Figure 11 A spot light

A spot light's hot angle is the half-angle (specified in radians) from the center of the cone of light within which the light remains at constant full intensity. In Figure 11 , h is the hot angle. A spot light's outer angle is the half angle (specified in radians) from the center of the cone to the edge of the cone. In Figure 11 , o is the outer angle.

The attenuation of the light's intensity from the edge of the hot angle to the edge of the outer angle is determined by the light's fall-off value. QuickDraw 3D allows you to specify no fall-off, a linear fall-off, an exponential fall-off, and a fall-off that is proportional to the cosine of the angle. The available fall-off algorithms are illustrated in Figure 12 .

See "Light Fall-Off Values" for a description of the constants you can use to specify a spot light's fall-off value.

Figure 12 Fall-off algorithms


© 1997 Apple Computer, Inc.

Previous | QD3D Book | Overview | Chapter Contents | Next |